package org.cx1.model.utils;

import org.apache.commons.lang.StringUtils;
import org.cx1.model.PosterType;

/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

/**
 *
 * @author ECH
 */
public class KPosterTypes {
    
    public static final PosterType LANDLORD = new PosterType(KPosterTypeIDs.LANDLORD, "Landlord", null, null);
    public static final PosterType AGENT = new PosterType(KPosterTypeIDs.LANDLORD, "Agent", null, null);
    public static final PosterType BROKER = new PosterType(KPosterTypeIDs.LANDLORD, "Broker", null, null);
    
    //CX: TODO: temporary service
    public static PosterType getPosterType(String id) {
        PosterType PosterType = null;
        if (StringUtils.equals(id, KPosterTypeIDs.LANDLORD)) {
            PosterType = LANDLORD;
        }
        else if (StringUtils.equals(id, KPosterTypeIDs.AGENT)) {
            PosterType = AGENT;
        }
        else if (StringUtils.equals(id, KPosterTypeIDs.BROKER)) {
            PosterType = BROKER;
        }
        return PosterType;
    }
}
